package com.company;

import java.util.Scanner;

public class Course {
    String number;
    String name;
    String place;
    String time;
    String teacher;
    int teacher1;
    int people;
    Course(String number,String name,String place,String time,String teacher,int teacher1,int people){
        this.number=number;
        this.name=name;
        this.place=place;
        this.time=time;
        this.teacher=teacher;
        this.teacher1=teacher1;
        this.people=people;
    }
    public void Timetable(Student a1,Student b1,Course a3,Course b3){
        System.out.println("按1查看学生小明信息，按2查看学生小红信息，按其他数字返回：");
        Scanner input2=new Scanner(System.in);
        int c2=input2.nextInt();
        if(c2==1){
            if(a1.course1==1){
                System.out.println(a1.number);
                System.out.println(a1.name);
                System.out.println(a1.grade);
                System.out.println(a3.number+" "+a3.name+" "+a3.place+" "+a3.time+" "+a3.teacher+" "+a3.people);
            }
            if(a1.course1==2){
                System.out.println(a1.number);
                System.out.println(a1.name);
                System.out.println(a1.grade);
                System.out.println(b3.number+" "+b3.name+" "+b3.place+" "+b3.time+" "+b3.teacher+" "+b3.people);
            }
            if(a1.course1==0){
                System.out.println("暂未选课");
            }
        }
        if(c2==2){
            if(b1.course1==1){
                System.out.println(b1.number);
                System.out.println(b1.name);
                System.out.println(b1.grade);
                System.out.println(a3.number+" "+a3.name+" "+a3.place+" "+a3.time+" "+a3.teacher+" "+a3.people);
            }
            if(b1.course1==2){
                System.out.println(b1.number);
                System.out.println(b1.name);
                System.out.println(b1.grade);
                System.out.println(b3.number+" "+b3.name+" "+b3.place+" "+b3.time+" "+b3.teacher+" "+b3.people);
            }
            if(b1.course1==0){
                System.out.println("暂未选课");
            }
        }
    }
}
